#include "advancesetworker.h"
#include "../model/osdremoteservicemodel.h"
#include "../remoteservice/configinfo.h"
#include "../remoteservice/networkinfo.h"
#include "../remoteservice/newversioninfo.h"
#include "../remoteservice/systemstatusinfo.h"
#include <QTime>
#include "../osdglobal.h"

AdvanceSetWorker::AdvanceSetWorker(QObject *parent) :
    QObject(parent)
{
}

void AdvanceSetWorker::work(int index)
{
    if (index == 0)
    {
        //是否启用dhcp
        OSDRemoteServiceModel::instance().config("enable_dhcp");
        //网络信息
        OSDRemoteServiceModel::instance().networkStatus();
    }
    else if (index == 1)
    {
        //呼叫速率
        OSDRemoteServiceModel::instance().config("call_rate");
        //自动应答
        OSDRemoteServiceModel::instance().config("auto_answer");
        //自动静音
        OSDRemoteServiceModel::instance().config("auto_mute_audio");
        //自动屏蔽视频
        OSDRemoteServiceModel::instance().config("auto_suspend_video");
        //会议提示
        OSDRemoteServiceModel::instance().config("conference_tips");
    }
    else if (index == 2)
    {
        //版本信息
        OSDRemoteServiceModel::instance().version();
    }
    else if (index == 3)
    {
        //系统信息
        OSDRemoteServiceModel::instance().systemStatus();
    }
}
